package Otros;

	import java.awt.*;
	import java.awt.event.*;
	import javax.swing.*;
	import javax.swing.table.*;
	 
	 
	/**
	 * @version 1.0 11/09/98
	 */
	  
	public class RowHeaderRenderer extends JLabel implements ListCellRenderer {
	   
	  public RowHeaderRenderer(JTable table) {
	    JTableHeader header = table.getTableHeader();
	    setOpaque(true);
	    setBorder(UIManager.getBorder("TableHeader.cellBorder"));
	    setHorizontalAlignment(CENTER);
	    setForeground(header.getForeground());
	    setBackground(header.getBackground());
	    setFont(header.getFont());
	    setPreferredSize(new Dimension(30, 21));
	  }
	  
	  public Component getListCellRendererComponent( JList list, 
	         Object value, int index, boolean isSelected, boolean cellHasFocus) {
	    setText((value == null) ? "" : value.toString());
	    return this;
	  }
	}